<?php
namespace Core\CoreContracts;

/*
* Account class definition
*/
class Account {

	/**
    * @property integer $Id The account unique identifier
    */
	public $Id;
	
	/**
    * @property integer $State The account state
    */
	public $State;
	
	/**
    * @property string $Name The account name
    */
	public $Name;
	
	/**
    * @property datetime $ModificationDate The account modification date
    */
	public $ModificationDate;
	
	/**
    * @property datetime $CreationDate The account creation date
    */
	public $CreationDate;
	
	/*
	* Build a new article object
	*
	* @param integer $state The account state 
	* @param string $name The account name
	*/
	public static function Create($state, $name)
	{
		$account = new Account();
		$account->State = $state;
		$account->Name = $name;
		$account->ModificationDate = date("Y-m-d H:i:s");
		$account->CreationDate = date("Y-m-d H:i:s");
		return $account ;
	}
}
?> 